
namespace Param
{
    public abstract class BaseArg
    {
        private string _StringArg;

        protected Args _Args;

        public string StringArg
        {
            get { return _StringArg; }
            set { _StringArg = value; }
        }

        public BaseArg Updated;
        public BaseArg(Args aArgs, string arg) : this(aArgs) { StringArg = arg; }
        public BaseArg(Args aArgs)
        {
            _Args = aArgs;
            Updated = this;
        }


        public abstract void Add(BaseArg obj);
        public virtual void AttachTo(ArgKey key) { _Args.AddToNamed(key.StringArg, ""); }
        public void AttachTo(ArgValue value) { _Args.AddToUnnamed(value.StringArg); }
        public void AttachTo(ArgNone none) { Updated = this; }
    }
}